package top.kangshuai.base;

import top.kangshuai.base.BaseEntity;
import top.kangshuai.entity.TbToken;
/**
 * 
 * @author ks187
 *
 */
import top.kangshuai.entity.TbTokenInfo;

public class BaseModel extends BaseEntity {
  private static final long serialVersionUID = -5702963644858342756L;
  private String token;

  public BaseModel() {
  }

  public String getToken() {
    return token;
  }

  public void setToken(String token) {
    this.token = token;
  }

  /**
   * getToken的委托方法，将客户端获取的token信息传递给TbToken对象
   * 
   * @return
   */
  public TbToken makeTokenInfo() {
    TbToken tbToken = new TbToken();
    tbToken.setToken(token);
    return tbToken;
  }

  /**
   * 获取tokeninfo的委托方法
   * 
   * @return
   */
  public TbTokenInfo getTbTokenInfo() {
    TbTokenInfo tokenInfo = new TbTokenInfo();
    tokenInfo.setToken(token);
    return tokenInfo;
  }
}
